#include <linux/mmzone.h>
#include <linux/list.h>

#define for_each_migratetype_order(order, type)      \
    for (order = 0; order < NR_PAGE_ORDERS; order++) \
        for (type = 0; type < MIGRATE_TYPES; type++)

static void zone_init_free_lists(struct zone *zone)
{
    unsigned int order, t;

    for_each_migratetype_order(order, t)
    {
        INIT_LIST_HEAD(&zone->free_area[order].free_list[t]);
        zone->free_area[order].nr_free = 0;
    }
}

void init_currently_empty_zone(struct zone *zone,
                               unsigned long zone_start_pfn,
                               unsigned long size)
{
    zone->zone_start_pfn = zone_start_pfn;

    zone_init_free_lists(zone);
}
